package com.zhangwei.exception;


import com.zhangwei.utils.StatusCode;

public class MyException extends RuntimeException {

    int code;

    public MyException(String message, int code) {
        super(message);
        this.code = code;
    }

    public MyException(StatusCode statusCode){
        super(statusCode.getDescription());
        this.code=statusCode.getCode();
    }

}
